/*
 * RefCount.h
 *
 *  Created on: Nov 10, 2008
 *      Author: brain
 */

#ifndef REFCOUNT_H_
#define REFCOUNT_H_

#include "Labelling.h"

class RefCount
{
private:
	int count;
	unsigned char *imdata;//* a pointer to imagedata, the array of the pixels
	static int diff_instances;//* number of all the different allocated images
public:
	uint color_bits;//* the depth bits
	IplImage *_data;//* the image (openCV)
	RefCount(IplImage * im);
	~RefCount();
	unsigned char *ImData();//*returns the imagedata
	void increase();//* increase pointing count
	void decrease();//* decrease pointing count
	void printcount();//* prints current counting
	uint depth();//* the depth of each channel

};

#endif /* REFCOUNT_H_ */
